This invention relates to an information processing unit comprising a central processing unit and a main memory unit and, in particular, to a data protection unit for protecting data in the main memory unit when a program for the central processing unit runs away.
As well known in the art, an information processing unit comprises a bus, a central processing unit (CPU), and a main memory unit (MMU). The central processing unit and the main memory unit are connected to the bus. The central processing unit carries out data processing in accordance with a program. The main memory unit memorizes data. The information processing unit may comprise a data channel. Each of the central processing unit and the data channel accesses the main memory unit. Therefore, each of the central processing unit and the data channel will be called a memory accessing unit for accessing the main memory unit. When the program runs away or has bugs, it is likely that destruction of the data occurs in the main memory unit. In order to permit protection of the data in the main memory unit from such destruction, the information processing unit comprises a protection facility.
A conventional protection facility comprises key register circuits which are mounted on the central processing unit and the data channel, respectively, and a lock register circuit mounted on the main memory unit. Each key register circuit is connected to the bus and comprises a plurality of key registers. The key registers hold key values each of which has one of logic zero and one values. The key values are initially set in the key registers by the program. The lock register circuit is connected to the bus and comprises a plurality of lock registers and a comparator. The lock registers hold lock values each of which is equal to one of logic zero and one values. The lock values are also initially set in the lock registers by the program. The comparator compares the key values held in the key registers with the lock values held in the lock registers. When a combination of the key values and the lock values satisfies a predetermined condition, the comparator produces a match signal. In this event, access to the main memory unit by the memory accessing unit is granted. In other words, the memory accessing unit may write the data in the main memory unit. Otherwise, the comparator produces a mismatch signal. Under the circumstances, access to the main memory unit by the memory accessing unit is prohibited.
In the conventional protection facility, the main memory unit has a memory space which is divided into a plurality of blocks and each block is assigned with a peculiar lock value and a peculiar key value. As a result, the main memory unit is protected from destruction of the data therein when the program runs away or has bugs. It is assumed that the memory accessing unit writes the data in the main memory unit when the program runs away. Under the circumstances, the data in the main memory unit is continuously destructed by the memory accessing unit until the memory accessing unit is reset in the conventional protection facility.